/**
 * Created by win7 on 2017/3/15.
 */
import Relay from "react-relay";

export default class TicklingListMutation extends Relay.Mutation {

    static fragments = {};

    getMutation() {
        return Relay.QL`mutation {  getSuggestList }`;
    }

    getVariables() {
        return {
            argsInput: {
                pageNum: this.props.pageNum,
                pageSize: this.props.pageSize
            }
        };
    }

    getFatQuery() {
        return Relay.QL`fragment on getSuggestListPayload {
            getSuggestList {
                errorCode
                value
                totalResult
                id
                suggestList{
                    sid
                    detail
                    updateDate
                    ifReply
                }
            }
        }`;
    }

    getConfigs() {
        return [{
            type: 'REQUIRED_CHILDREN',
            children: [Relay.QL`
                fragment on getSuggestListPayload {
            getSuggestList {
                errorCode
                value
                totalResult
                id
                    suggestList{
                        sid
                        detail
                        updateDate
                        ifReply
                    }
                }
                }
            `]
        }];
    }

}